
<% content_tag :div, :class => 'bigwrapper' do%>
<%= flash[:error] %>
		<% content_tag :div, :class => 'header' do -%>
			<%= content_tag :img, nil, :src => '/images/icons/icons_02.png', :class => 'hleft' %>
			<%= content_tag :span, 'New Action',:class => 'hleft' %>
			<% content_tag :span, :class => 'headertext' do -%>
				<%= content_tag :strong, 'Welcome to Sparktools!' -%>
				<%= content_tag :p, 'Sparktools is an online application that allows student organization leaders to keep track of their projects, finances, and contacts. Student organizations' -%>
			<% end -%>
		<% end -%>
		<% form_tag :action => 'new' do -%>
			<%= hidden_field :action_item, :group_id, :value => @group_id %>
			<%= hidden_field :action_item_entry, :status, :value => "Unopened"%>
		<% content_tag :div, :class => 'mainbox' do %>
			<%= content_tag :h3, '1. Project association'%>
			<%= content_tag :span, "Select the project that this action belongs to (<span class='red'>*</span>): " %>
			<%= content_tag(:span,select(:action_item, :project_id, @projects.collect {|p| [p.first_entry.name, p.id]}, { :include_blank => true, :selected => params[:project_id].to_i }))%>
		<% end -%>
		<% content_tag :div, :class => 'mainbox' do %>
			<%= content_tag :h3, '2. Description'%>
			<%= content_tag :p, "Title for new action (<span class='red'>*</span>): " %>
			<%= content_tag(:div,text_field(:action_item_entry, :name)) %>
			<%= content_tag :p, "Main text ( usually should define the scope of the action ) (<span class='red'>*</span>): " %>
			<%= content_tag(:div,text_area(:action_item_entry, :note, {:size=>"70x4"})) %>
		<% end -%>
		<% content_tag :div, :class => 'mainbox' do -%>
			<% content_tag :div, :class => 'duecolumn' do -%>
				<%= content_tag :h3, '3. Due date'%>
				<%= content_tag :p, "Date the action is due ( may be changed later ) (<span class='red'>*</span>): " %>
				<%= calendar_date_select :action_item_entry, :due, :embedded => true %>
			<% end -%>
			<% content_tag :div, :class => 'additionalcolumn' do -%>
				<%= content_tag :h3, '4. Additional'%>
				<%= content_tag :p, "Assign this action item to a user: " %>
				<%= content_tag(:span, select(:action_item_entry, :assigned_to_id, @users.collect {|u| [u.login, u.id]}, :selected => current_user.id ))%>
			<% end -%>
			<% content_tag :div, :class => 'savecolumn' do -%>
				<%= content_tag :h3, '5. Save'%>
				<%= content_tag :p, "Once everything is filled out, click save to create this action item." %>
				<%= submit_tag 'Create Action' %>
			<% end -%>
		<% end -%>
	<% end %>
<% end -%>